{extend name="public/common"} {block name="body"}
<title>基本设置</title>
<style type="text/css">
	table tbody {
		display:block;
		height:650px;
		overflow-y:scroll;
		}
		
	table thead, tbody tr {
		display:table;
		width:100%;
		table-layout:fixed;
		}
		
	table thead {
		width: calc( 99.87% - 1em )
		}
	/*.bg-1 {
    background-color: #ffffff !important;
    border-color: #ffffff !important;
}*/
.l{
	color: #fff;
    background-color: #636363;
    border-color: #636363;
    /* border-radius: 5px; */
    text-align: center;
    width: 105px;
    line-height: 40px;
    }
</style>
</head>
<body>
  <nav class="breadcrumb">
    <i class="Hui-iconfont">&#xe67f;</i>
    
    彩票管理
    <span class="c-gray en">&gt;</span>
    限额设置
    <a class="btn btn-success radius r"
      style="line-height: 1.6em; margin-top: 3px"
      href="javascript:location.replace(location.href);" title="刷新">
      <i class="Hui-iconfont">&#xe68f;</i>
    </a>
  </nav>
  
  <div style="padding:20px;height:30px;">
  	
  	<div class="new_box">
  <div class="cl pd-5 bg-1 bk-gray mt-20"> <span class="l" style="font-size: 14px;"> 玩法限额设置</span></div>

<form class="am-form am-g"  method="post">
     <div class="page-container">
      <div id="tab-system" class="HuiTab">
        <div class="tabCon">
          <div class="mt-20">
            <table
              class="table table-border table-bordered table-bg table-hover table-sort table-responsive">
              <thead>
                <tr class="text-c">
                  <th >ID</th>
                  <th >玩法名称</th>
                  <th >最高单注投注金额(0为不限制)</th>
                </tr>
                
              </thead>
              <tbody>
          {volist name="list" id="v"}
              
              
                <tr class="text-c">
                  <td>{$v.id}</td>
                  <td>{$v.class_name_mini}</td>
                  <td>
                    <input type="number" name="{$v.id}" value="{$v.max_money}" style="font-size:12px; text-align:center; width:200px; height:30px" onchange="updateMlInfo(this.value,this.name)" onkeypress="if(event.keyCode == 13){ blur()}" />
                  </td>

                </tr>
              {/volist}
              </tbody>
            </table>
          </div>
        </div>
      </div>
    </div>
    </div>
    </div>
    <div class="am-margin" style="margin-top:20px;margin-bottom:20px;">

   
  </div>
</form>
{/block}{block name="js"}
 <script type="text/javascript" src="__SYSMET__/lib/My97DatePicker/4.8/WdatePicker.js"></script> 
<script type="text/javascript">
$(function() {
  $('.skin-minimal input').iCheck({
    checkboxClass : 'icheckbox-blue',
    radioClass : 'iradio-blue',
    increaseArea : '20%'
  });
  $("#tab-system").Huitab({
    index : 0
  });
});
</script>
<script type="text/javascript">
function updateMlInfo(value,name) {
	$.ajax({
        type : "post",
        url : "{:url('lottery/updateMlInfo')}",
        data : {"name":name,"value":value},
        success: function (data) {
        	if(!data) {
        		alert("更新失败请重试！");
        	} else {
        		alert("更新成功");
        	}
        }
    });
}
</script>

{/block}
